/* 当前这个模块对所有api接口进行统一管理 */
import requests from './request';
import mockRequests from './mockAjax';
//三级联动接口
//http://39.98.123.211/api/product/getBaseCategoryList   get请求  无参数

export const reqCategoryList = () =>
  requests({ url: '/product/getBaseCategoryList', method: 'get' });

// 获取banner(Home首页轮播图接口)
export const reqGetBannerList = () => mockRequests.get('/banner');

// 获取floors数据
export const reqFloorsList = () => mockRequests.get('/floors');

// 获取搜搜模块数据 路径:/api/list   POST请求
/* 
  {
  "category3Id": "61",
  "categoryName": "手机",
  "keyword": "小米",
  "order": "1:desc",
  "pageNo": 1,
  "pageSize": 10,
  "props": ["1:1700-2799:价格", "2:6.65-6.74英寸:屏幕尺寸"],
  "trademark": "4:小米"
}

*/
// 当前这个接口,给服务器传递的参数params,至少是个空对象
export const reqGetSearchInfo = (params) =>
  requests({
    url: '/list',
    method: 'post',
    data: params,
  });
